<!-- END SIDEBAR -->
  <!-- BEGIN CONTENT -->
  <div class="col-md-9 col-sm-8">
	<h2>Hàng Bán Chạy nhất</h2>
	<div class="owl-carousel owl-carousel3"><?php
	if(!empty($most_wanted)):
	  foreach($most_wanted as $v):
		$img = $v['p_image'];
		if(empty($img)):
			$img = $thumb = '/assets/img/notfound.jpg';
		else:
			$thumb = '/assets/upload/thumbs/'.$img;
			$img = '/assets/upload/'.$img;
		endif;
	  ?><div>
		<div class="product-item">
		  <div class="pi-img-wrapper">
			<img src="<?php echo $thumb; ?>" class="img-responsive product-image full" alt="<?php echo html_escape($v['p_name']); ?>">
			<div>
			  <a href="<?php echo $img; ?>" class="btn btn-default fancybox-button">Phóng to</a>
			  <a href="#product-pop-up" class="btn btn-default fancybox-fast-view">Xem</a>
			</div>
		  </div>
		  <h3><a href="<?php echo base_url('/product/view/'.$v['p_id']); ?>"><?php echo html_escape($v['p_name']); ?></a></h3>
		  <div class="pi-price"><?php echo $v['p_price']; ?> Đ</div>
		</div>
	</div>
	  <?php
	  endforeach;
	else:
		?><div>Tạm thời chưa có sản phẩm nào</div><?php
	endif; 
	  ?>
	</div>
  </div>
  <!-- END CONTENT -->
</div>
<!-- END SIDEBAR & CONTENT -->

<!-- BEGIN TWO PRODUCTS & PROMO --><?php
if(!empty($special)):

?><div class="row margin-bottom-35 ">
  <!-- BEGIN TWO PRODUCTS -->
  <div class="col-md-12">
	<h2>Sản phẩm khác</h2>
	<div class="owl-carousel owl-carousel4"><?php
	foreach($special as $v):
		$img = $v->getImage();
		if(empty($img)):
			$img = $thumb = '/assets/img/notfound.jpg';
		else:
			$thumb = '/assets/upload/thumbs/'.$img->getName();
			$img = '/assets/upload/'.$img->getName();
		endif;
	  ?><div>
		<div class="product-item">
		  <div class="pi-img-wrapper">
			<img src="<?php echo $thumb; ?>" class="img-responsive product-image full" alt="<?php echo html_escape($v->getName()); ?>">
			<div>
			  <a href="<?php echo $img; ?>" class="btn btn-default fancybox-button">Phóng to</a>
			  <a href="#product-pop-up" class="btn btn-default fancybox-fast-view">Xem</a>
			</div>
		  </div>
		  <h3><a href="<?php echo base_url('/product/view/'.$v->getId()); ?>"><?php echo html_escape($v->getName()); ?></a></h3>
		  <div class="pi-price"><?php echo $v->getPrice(); ?> Đ</div>
		</div>
	  </div><?php
	endforeach;
	?></div>
  </div>
  <!-- END TWO PRODUCTS -->
</div><?php
endif;
?>
<!-- END TWO PRODUCTS & PROMO -->

